<template>
	<view class="box">
		<view class="concten">
			<text>{{text}}</text>
		</view>
		<view class="top" @click="close">
		x
		</view>
	</view>
</template>

<script>
	export default {
		name:"tag-item",
		data() {
			return {
			};
		},
		props:['text'],
		methods:{
			close(){
				this.$emit("Clsoe",this.text)
				console.log('666')
			},
			
		}
	}
</script>

<style lang="scss">
.box{
	margin-right: 10rpx;
	margin-top: 10rpx;
	position: relative;
	
	.concten{
		display: inline-block;
		background-color: #eee;
		text{
			font-size: 20rpx;
			font-family: '楷体';
			border-radius: 15rpx;
			font-weight: 800;
			padding: 15rpx;
		}
	}
	.top{
		position: absolute;
		right: -1px;
		font-size: 20rpx;
		top:-19rpx;
	}
}
</style>